\testfile{pgfplotstest.enlargelimits.tex}
\testsection{Limit computation}
\testsubsection{User specified limits}
{\pgfplotsset{every axis/.append style={scaled ticks=false,enlargelimits=false}}
[scaled ticks = false,enlargelimits=false] in this section
\testsubsubsection{linear plot, unconstraint}
\starttikzpicture
	\startaxis
		\addplot file{pgfplots.testplot};
	\stopaxis
\stoptikzpicture

\testsubsubsection{linear plot, limited to $x \in [-20,20]$}
\starttikzpicture
	\startaxis[xmin=-20,xmax=20]
		\addplot file{pgfplots.testplot};
	\stopaxis
\stoptikzpicture

\testsubsubsection{linear plot, limited to $y \in [-12000,800]$}
\starttikzpicture
	\startaxis[ymin=-12000,ymax=800]
		\addplot file{pgfplots.testplot};
	\stopaxis
\stoptikzpicture

\testsubsubsection{linear plot, limited to $x \in [-20,20]; y \in [-12000,800]$}
\starttikzpicture
	\startaxis[xmin=-20,xmax=20,ymin=-12000,ymax=800]
		\addplot file{pgfplots.testplot};
	\stopaxis
\stoptikzpicture

\testsubsubsection{linear plot, limited to empty $x$-range}
\starttikzpicture
	\startaxis[xmin=2000,xmax=20000]
		\addplot file{pgfplots.testplot};
	\stopaxis
\stoptikzpicture



\testsubsection{Log plots}
Log--plots use the same code; they should work in the same way!

\testsubsubsection{log plot unconstraint}
\starttikzpicture
	\startloglogaxis
		\loglogtestplot
	\stoploglogaxis
\stoptikzpicture

\testsubsubsection{log plot limited to $x \in [10^3,5\cdot 10^5]$}
\starttikzpicture
	\startloglogaxis[xmin=1e3,xmax=5e5]
		\loglogtestplot
	\stoploglogaxis
\stoptikzpicture

\testsubsubsection{log plot limited to $y \in [10^{-5},2\cdot 10^{-3}]$}
\starttikzpicture
	\startloglogaxis[ymin=1e-5,ymax=2e-3]
		\loglogtestplot
	\stoploglogaxis
\stoptikzpicture
}

\testsubsection{Enlargelimits tests}
\testsubsubsection{enlargelimits=false, x limits provided}
\starttikzpicture
\startaxis[%
	enlargelimits=false,
	xmin=0,xmax=1,
	xtick={-1.5,-1.25,...,1.5}]
\smallplotstest
\stopaxis
\stoptikzpicture

\testsubsubsection{enlargelimits=false, no limits provided}
\starttikzpicture
\startaxis[enlargelimits=false]
\smallplotstest
\stopaxis
\stoptikzpicture

\testsubsubsection{enlargelimits=true, all limits provided $[-1,1]\times [-1,1]$}
\starttikzpicture
\startaxis[enlargelimits=true,xmin=-1,xmax=1,ymin=-1,ymax=1]
\smallplotstest
\stopaxis
\stoptikzpicture

\testsubsubsection{enlargelimits=0.5}
\starttikzpicture
\startaxis[enlargelimits=0.5]
\smallplotstest
\stopaxis
\stoptikzpicture
